package entity_controllers.cards;

import ie.FieldBoard;
import ie.PlayerBoard;
import ie.Shaker;
import dto.Player;
import entity.Account;
import entity_controllers.Card;
import entity_controllers.options.effects.JailEffect;

public class FreeJailCard extends Card {

	public FreeJailCard() {
		super("I anledningen af kongens fødselsdag benådes de herved fra fængsel. Dette kort kan opbevares, indtil De får brug for det.");
	}

	@Override
	public void execute(Player player, FieldBoard fieldBoard, PlayerBoard playerBoard, Shaker shaker) {

		//Adds a jail card to the player
		((JailEffect)((Account)player.getAccount()).getEM().getOption(JailEffect.class)).addJailCard();

	}

}
